<h1><%= title "Characters" %></h1>

<table>
  <tr>
    <th>Name</th>
    <th>Player</th>
    <th>Father</th>
    <th>Mother</th>
    <th>Culture</th>
	<th>Sex</th>
	<th>Age</th>
    <th>Prestige</th>
    <th>Piety</th>
    <th>Wealth</th>
	<th>Highest Title</th>
  </tr>

<% for character in @characters %>
  <tr>
    <td><%=h character.christian_name %>&nbsp;<%=h character.family_name %></td>
    <td><%= show_player character.player %></td>
    <td><%= link_to_father character %></td>
    <td><%= link_to_mother character %></td>
    <td><%= link_to_record character.culture %></td>
	<td><%=h character.sex %></td>
	<td><%=h character.age %></td>
    <td><%=h character.prestige %></td>
    <td><%=h character.piety %></td>
    <td><%=h character.wealth %></td>
	<td><%=link_title character.highest_title %></td>
    <td><%= link_to 'Show', character %></td>
    <td><%= link_to 'Edit', edit_character_path(character) %></td>
    <td><%= link_to 'Kill', character, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New character', new_character_path %> | <%= link_to 'Home', '/' %>
